import http from '../http'

const dataset = {
  add(data) {
    return http('/api/dataset/add', 'post', data)
  },
  delete(data) {
    return http('/api/dataset/delete', 'post', data)
  },
  update(data) {
    return http('/api/dataset/update', 'post', data)
  },
  getChildrenById({ id }) {
    return http(`/api/dataset/getChildrenById?id=${id}`, 'get')
  }
}

export default dataset